import request from '@/utils/request'

// 报表 审核
export function checkSave(params: any) {
  if(params.status==2){
    return request.post({ url: '/report.check/index', params })
  }else{
    return request.post({ url: '/report.check/bohui', params })
  }
}

// 获取报表有多少条未审核 获取
export function getNocheck(params?: any) {
    return request.get({ url: '/report.check/getNocheck', params })
}

// 获取库存有多少条未审核 获取
export function getStockNocheck(params?: any) {
    return request.get({ url: '/report.check/getStockNocheck', params })
}

// 当班调度 获取
export function getDispatch(params?: any) {
    return request.get({ url: '/report.check/getDispatch', params })
}
// 当班调度 保存
export function dispatchSave(params: any) {
    return request.post({ url: '/report.check/dispatchSave', params })
}



// 库存审核
export function checkStock(params: any) {
  if(params.status==2){
    return request.post({ url: '/report.check/checkStock', params })
  }else{
    return request.post({ url: '/report.check/bohuiStock', params })
  }
}

// 报表导出
export function exportExcelApi(params: any) {
    return request.post({ url: '/report.check/exportExcel', params }, { ignoreCancelToken: true })
}

// 库存导出
export function exportExcelStockApi(params: any) {
    return request.post({ url: '/report.check/exportExcelStock', params }, { ignoreCancelToken: true })
}
